Skip to content

mise: Add Version 2025.1.6 - #6374

Merged
chawyehsu merged 12 commits into
ScoopInstaller:masterfrom
FilipDeVos:6329-mise
Jan 13, 2025
Merged

chawyehsu merged 12 commits into
ScoopInstaller:masterfrom
FilipDeVos:6329-mise

Conversation

@FilipDeVos

Copy link
Copy Markdown
Contributor

This pull request adds the manifest to install the "mise-en-place" tool from https://github.com/jdx/mise/

Closes #6329

  • Use conventional PR title: <manifest-name[@version]|chore>: <general summary of the pull request>
  • I have read the Contributing Guide

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

github-actions Bot commented Dec 9, 2024

Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

mise

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

1 similar comment
@github-actions

github-actions Bot commented Dec 9, 2024

Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

mise

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@FilipDeVos FilipDeVos changed the title mise: Add version 2024.12.3 mise@2024.12.3: Add initial version of manifest Dec 9, 2024
@FilipDeVos FilipDeVos changed the title mise@2024.12.3: Add initial version of manifest mise: Add version 2024.12.3 Dec 9, 2024
@FilipDeVos FilipDeVos changed the title mise: Add version 2024.12.3 mise@2024.12.3: Add manifest Dec 9, 2024
@FilipDeVos

Copy link
Copy Markdown
Contributor Author

I am trying to do the right thing with the PR title, but the documentation is contradicting.

  • For buckets it says: If it's a new manifest, use : Add version .
  • In the PR template it says: use conventional commits.

@o-l-a-v

o-l-a-v commented Dec 9, 2024 •

Copy link
Copy Markdown
Contributor

If we want mise to be purged if scoop uninstall --purge mise, which I guess we do, then add something like:

{
  "post_uninstall": [
        "if ($purge) {",
        "    $Directories = [string[]](",
        "        ('{0}\\mise' -f $env:LOCALAPPDATA),",
        "        ('{0}\\Temp\\mise' -f $env:LOCALAPPDATA)",
        "    )",
        "    $Directories.ForEach{",
        "        if (Test-Path -Path $_ -PathType 'Container') {",
        "            $null = Remove-Item -Path $_ -Recurse -Force",
        "        }",
        "    }",
        "}"
    ]
}

@nagromc

nagromc commented Dec 9, 2024

Copy link
Copy Markdown
Contributor

I was about to submit a PR; thanks @FilipDeVos!

I suggest two things:

  1. Use a more precise description. The About page is pretty good IMO:

    Development environment setup tool

  2. Use the full name as the app ID: i.e. mise-en-place.json instead of mise.json

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

I noticed that we need to add $env:LOCALAPPDATA\mise\shims to $env:PATH

I'll research a bit what the best way of doing this is.

@o-l-a-v

o-l-a-v commented Dec 9, 2024 •

Copy link
Copy Markdown
Contributor
Scratch this idea

Maybe "post_install" to add it with PowerShell, and "post_uninstall" to remove it? In user context. Something like this (untested):

[System.Environment]::SetEnvironmentVariable(
   'Path',
   ('{0};{1}\mise\shims' -f [System.Environment]::GetEnvironmentVariable('Path','User'), $env:LOCALAPPDATA),
  'User'
)

Edit: Scratch the above, seems Scoop has env_add_path which can be used for this?

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

env_add_path only supports folders under the installation folder I think.

@FilipDeVos

FilipDeVos commented Dec 9, 2024 •

Copy link
Copy Markdown
Contributor Author

I think this commit does the trick.

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

github-actions Bot commented Dec 9, 2024

Copy link
Copy Markdown
Contributor

Your changes do not pass checks.

mise-en-place

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

github-actions Bot commented Dec 9, 2024

Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

mise-en-place

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@FilipDeVos FilipDeVos changed the title mise@2024.12.3: Add manifest mise@2024.12.22: Add manifest Dec 30, 2024
@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

mise

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@FilipDeVos FilipDeVos changed the title mise@2024.12.22: Add manifest mise: Add Version 2024.12.22 Dec 30, 2024
@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

Copy link
Copy Markdown
Contributor

Your changes do not pass checks.

mise

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@FilipDeVos

Copy link
Copy Markdown
Contributor Author

/verify

@github-actions

github-actions Bot commented Jan 1, 2025

Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

mise

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

@jdx

jdx commented Jan 12, 2025

Copy link
Copy Markdown

anything I can do to help with this? we've managed to get into winget and chocolatey, I'm sure scoop users would love to have mise too!

@chawyehsu chawyehsu changed the title mise: Add Version 2024.12.22 mise: Add Version 2025.1.6 Jan 13, 2025
@chawyehsu
chawyehsu merged commit 05c81f8 into ScoopInstaller:master Jan 13, 2025
@chawyehsu

Copy link
Copy Markdown
Member

Hello, I just reviewed and approved it.

@jdx Since you commented here, may I ask if it's good to support customizing the mise home directory via env var (sth like MISE_HOME), so we could relocate and persist the data with Scoop?

@jdx

jdx commented Jan 13, 2025

Copy link
Copy Markdown

I'm not sure I understand what "relocate and persist" would be for, no other package manager for mise does anything like that I don't think

@chawyehsu

Copy link
Copy Markdown
Member

For Scoop, portable mode is preferred when it's available, currently the data (shims/installs/downloads etc.) of mise are stored outside of the install.

Nevermind, I searched the mise codebase and found envs MISE_DATA_DIR that could be used to change the default location. I think it already satisfies.

@chawyehsu

Copy link
Copy Markdown
Member

Okay this is the diff, and if anyone wants to contribute they could open a new PR with it.

diff --git a/bucket/mise.json b/bucket/mise.json
index 531d459f7..5a9c32a66 100644
--- a/bucket/mise.json
+++ b/bucket/mise.json
@@ -15,25 +15,11 @@
     },
     "extract_dir": "mise",
     "bin": "bin/mise.exe",
-    "installer": {
-        "script": "Add-Path -Path \"$env:LOCALAPPDATA\\mise\\shims\" -Global:$global"
+    "env_set": {
+        "MISE_DATA_DIR": "$dir\\mise"
     },
-    "uninstaller": {
-        "script": "Remove-Path -Path \"$env:LOCALAPPDATA\\mise\\shims\" -Global:$global"
-    },
-    "post_uninstall": [
-        "if ($purge) {",
-        "    $Directories = [string[]](",
-        "        ('{0}\\mise' -f $env:LOCALAPPDATA),",
-        "        ('{0}\\Temp\\mise' -f $env:LOCALAPPDATA)",
-        "    )",
-        "    $Directories.ForEach{",
-        "        if (Test-Path -Path $_ -PathType 'Container') {",
-        "            $null = Remove-Item -Path $_ -Recurse -Force",
-        "        }",
-        "    }",
-        "}"
-    ],
+    "env_add_path": "mise\\shims",
+    "persist": "mise",
     "checkver": {
         "github": "https://github.com/jdx/mise"
     },

ev-dev added a commit to ev-dev/scoop-main that referenced this pull request Jan 13, 2025
…nal env vars

Included manifest changes suggested by @chawyehsu in PR ScoopInstaller#6374 which sets the internal mise configurable env var MISE_DATA_DIR to a directory that scoop persists
@ev-dev

ev-dev commented Jan 13, 2025

Copy link
Copy Markdown
Contributor

the changes @chawyehsu mentioned seem ideal, made a PR with the changes at #6453

@FilipDeVos
FilipDeVos deleted the 6329-mise branch January 13, 2025 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Request]: mise

9 participants